package cn.fsd.exception;

import lombok.Data;
import lombok.EqualsAndHashCode;

@Data
@EqualsAndHashCode(callSuper = true)
public class StoreroomException extends RuntimeException{

    private Integer code;
    private String msg;

    public StoreroomException(StoreroomExceptionCodeMsg storeroomExceptionCodeMsg){
        this.code = storeroomExceptionCodeMsg.getCode();
        this.msg = storeroomExceptionCodeMsg.getMsg();
    }

    public StoreroomException(Integer code, String msg){
        this.code = code;
        this.msg = msg;
    }

}
